import java.util.Arrays;
import java.util.Scanner;

public class Test {
    public static void main2(String[] args) {
        int a = 0 ;
        int b = 0 ;
        Scanner scan = new Scanner(System.in) ;
        System.out.println("输入n");
        a = scan.nextInt() ;
        System.out.println("输入m");
        b = scan.nextInt() ;
        if( a == b ){
            System.out.println(a);
        }else if(a > b){
            int c = a % b ;
           while(c != 0){
               a = b ;
               b = c ;
               c = a % b ;
           }
            System.out.println("最大公约数" + b);
        }else{
            int c = b % a ;
            while(c != 0 ){
                b = a ;
                a = c ;
                c = b % a ;
            }
            System.out.println("最大公约数" + a);
        }


    }

    public static boolean leapYear(int year){
        if((year % 4 == 0 && year % 100 != 0) || year % 400 == 0){
            return true ;
        }
        return false ;
    }

    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        String s = scan.nextLine();
        
    }

}
